/*!
\copyright  Copyright (c) 2020 Qualcomm Technologies International, Ltd.\n
            All Rights Reserved.\n
            Qualcomm Technologies International, Ltd. Confidential and Proprietary.
\file
\brief      Unit tests for uart.c.
*/

/*-----------------------------------------------------------------------------
------------------ INCLUDES ---------------------------------------------------
-----------------------------------------------------------------------------*/

#include "unity.h"

#include "uart.c"

#include "mock_stm32f0xx_usart.h"
#include "mock_stm32f0xx_rcc.h"
#include "mock_cli.h"
#include "mock_power.h"

#ifdef VARIANT_ST2
#include "mock_charger_comms.h"
#endif

/*-----------------------------------------------------------------------------
------------------ PROTOTYPES -------------------------------------------------
-----------------------------------------------------------------------------*/

/*-----------------------------------------------------------------------------
------------------ VARIABLES --------------------------------------------------
-----------------------------------------------------------------------------*/

uint32_t SystemCoreClock;

/*-----------------------------------------------------------------------------
------------------ DO FUNCTIONS -----------------------------------------------
-----------------------------------------------------------------------------*/

/*-----------------------------------------------------------------------------
------------------ FUNCTIONS --------------------------------------------------
-----------------------------------------------------------------------------*/

void setUp(void)
{
    memset(test_AHBPERIPH, 0, sizeof(test_AHBPERIPH));
    memset(test_APBPERIPH, 0, sizeof(test_APBPERIPH));

    SystemCoreClock = 8000000;

    memset(&uart_info, 0, sizeof(uart_info));

    uart_init();
}

void tearDown(void)
{
}

/*-----------------------------------------------------------------------------
------------------ TESTS ------------------------------------------------------
-----------------------------------------------------------------------------*/

/*
* UART.
*/
void test_uart(void)
{
}
